source /etc/profile
. ~/.bash_profile
#!/bin/bash

ps -ef|grep "detection.php"|grep -v grep
if [ $? -eq 0 ];then
        `ps -ef | grep "detection.php"| awk '{print $2}' | xargs kill -9`
	nohup /usr/local/php/bin/php /data/wwwroot/xiuxian/shell/detection.php &
#	sleep 5
#        /usr/local/php/bin/php detection.php & > /dev/null 2>&1
else
        nohup /usr/local/php/bin/php detection.php & > /dev/null 2>&1


fi

